const yargs = require('yargs')
const Server = require('./app')
const argv = yargs
	.usage('anywhere [options]')
	.option('p',{
		alias:'port',
		describe:'端口号',
		default: 9529
	})
	.option('h',{
		alias:'hostname',
		describe:'host',
		default:'127.0.0.1'
	})
	.option('d',{
		alias:'root',
		describe:'root path',
		default:process.cwd()
	})
	.version()
	.alias('v','version')
	.help()
	.argv

const server = new Server(argv)
server.start()

//chmod +x bin/jtr354-anydoor 打开权限

// npm login	登录
// npm publish	发布

//eES7的async
//npm i --save-dev babel-plugin-transform-runtime

